home *** CD-ROM | disk | FTP | other *** search
/ MacAddict 108 / MacAddict108.iso / Software / Internet & Communication / WordPress 1.5.1.dmg / wordpress / wp-admin / edit-form-comment.php < prev    next >
Encoding:
PHP Script  |  2005-03-10  |  3.5 KB  |  90 lines

  1. <?php
  2. $submitbutton_text = __('Edit Comment »');
  3. $toprow_title = sprintf(__('Editing Comment # %s'), $commentdata['comment_ID']);
  4. $form_action = 'editedcomment';
  5. $form_extra = "' />\n<input type='hidden' name='comment_ID' value='$comment' />\n<input type='hidden' name='comment_post_ID' value='".$commentdata["comment_post_ID"];
  6. ?>
  7.  
  8. <form name="post" action="post.php" method="post" id="post">
  9. <div class="wrap">
  10. <input type="hidden" name="user_ID" value="<?php echo $user_ID ?>" />
  11. <input type="hidden" name="action" value='<?php echo $form_action . $form_extra ?>' />
  12.  
  13. <script type="text/javascript">
  14. function focusit() {
  15.     // focus on first input field
  16.     document.post.name.focus();
  17. }
  18. window.onload = focusit;
  19. </script>
  20. <fieldset id="namediv">
  21.     <legend><?php _e('Name:') ?></legend>
  22.     <div>
  23.       <input type="text" name="newcomment_author" size="22" value="<?php echo format_to_edit($commentdata['comment_author']) ?>" tabindex="1" id="name" />
  24.     </div>
  25. </fieldset>
  26. <fieldset id="emaildiv">
  27.         <legend><?php _e('E-mail:') ?></legend>
  28.         <div>
  29.           <input type="text" name="newcomment_author_email" size="30" value="<?php echo format_to_edit($commentdata['comment_author_email']) ?>" tabindex="2" id="email" />
  30.     </div>
  31. </fieldset>
  32. <fieldset id="uridiv">
  33.         <legend><?php _e('URI:') ?></legend>
  34.         <div>
  35.           <input type="text" name="newcomment_author_url" size="35" value="<?php echo format_to_edit($commentdata['comment_author_url']) ?>" tabindex="3" id="URL" />
  36.     </div>
  37. </fieldset>
  38.  
  39. <fieldset style="clear: both;">
  40.         <legend><?php _e('Comment') ?></legend>
  41. <?php the_quicktags(); ?>
  42. <?php
  43.  $rows = get_settings('default_post_edit_rows');
  44.  if (($rows < 3) || ($rows > 100)) {
  45.      $rows = 10;
  46.  }
  47. ?>
  48. <div><textarea rows="<?php echo $rows; ?>" cols="40" name="content" tabindex="4" id="content" style="width: 99%"><?php echo $content ?></textarea></div>
  49. </fieldset>
  50.  
  51. <script type="text/javascript">
  52. <!--
  53. edCanvas = document.getElementById('content');
  54. //-->
  55. </script>
  56.  
  57. <p class="submit"><input type="submit" name="editcomment" id="editcomment" value="<?php echo $submitbutton_text ?>" style="font-weight: bold;" tabindex="6" />
  58.   <input name="referredby" type="hidden" id="referredby" value="<?php echo $_SERVER['HTTP_REFERER']; ?>" />
  59. </p>
  60.  
  61. </div>
  62.  
  63. <div class="wrap">
  64. <h2><?php _e('Advanced'); ?></h2>
  65.  
  66. <table width="100%" cellspacing="2" cellpadding="5" class="editform">
  67.     <tr>
  68.         <th scope="row" valign="top"><?php _e('Comment Status') ?>:</th>
  69.         <td><label for="comment_status_approved" class="selectit"><input id="comment_status_approved" name="comment_status" type="radio" value="1" <?php checked($comment_status, '1'); ?> /> <?php _e('Approved') ?></label><br />
  70.       <label for="comment_status_moderated" class="selectit"><input id="comment_status_moderated" name="comment_status" type="radio" value="0" <?php checked($comment_status, '0'); ?> /> <?php _e('Moderated') ?></label><br />
  71.       <label for="comment_status_spam" class="selectit"><input id="comment_status_spam" name="comment_status" type="radio" value="spam" <?php checked($comment_status, 'spam'); ?> /> <?php _e('Spam') ?></label></td>
  72.     </tr>
  73.  
  74. <?php if ($user_level > 4) : ?>
  75.     <tr>
  76.         <th scope="row"><?php _e('Edit time'); ?>:</th>
  77.         <td><?php touch_time(('editcomment' == $action), 0); ?></td>
  78.     </tr>
  79. <?php endif; ?>
  80.  
  81.     <tr>
  82.         <th scope="row"><?php _e('Delete'); ?>:</th>
  83.         <td><p><a class="delete" href="post.php?action=confirmdeletecomment&noredir=true&comment=<?php echo $commentdata['comment_ID']; ?>&p=<?php echo $commentdata['comment_post_ID']; ?>"><?php _e('Delete comment') ?></a></p></td>
  84.     </tr>
  85. </table>
  86.  
  87. </div>
  88.  
  89. </form>
  90.